package org.example.web.exception;

import org.example.web.result.StateCode;


/**
 * 服务端内部异常
 */
public class ServerException extends AbstractException {

    public ServerException() {
        super();
    }

    public ServerException(String errorMessage) {
        super(errorMessage, null);
    }

    public ServerException(StateCode stateCode) {
        super(stateCode.message(), stateCode.code());

    }

    protected ServerException(String errorMessage, String errorCode) {
        super(errorMessage, errorCode);
    }

    protected ServerException(String errorMessage, Throwable throwable, StateCode stateCode) {
        super(errorMessage, throwable, stateCode);
    }
}
